<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
    <head>
        <title>CSS Test: An animation will not derive keyframes from more than one @keyframes rule</title>
        <link rel="author" title="Microsoft" href="http://www.microsoft.com/" />
        <link rel="help" href="http://www.w3.org/TR/css3-animations/#keyframes-" />
        <meta name="flags" content="animated dom" />
        <meta name="assert" content="An animation will not derive keyframes from more than one @keyframes rule" />
        <style type="text/css">
            @keyframes testAnimation
            {
                33% {left: 225px; top: 0px;}
            }
            @keyframes testAnimation
            {
                66% {left: 225px; top: 400px;}
            }
            @keyframes testAnimation
            {
                from {left: 10px; top: 200px;}
                to {left: 500px; top: 200px;}
            }
            #parent
            {
                position: relative;
            }
            #start
            {
                background-color: orange;
                height: 50px;
                left: 10px;
                position: absolute;
                top: 200px;
                width: 50px;
            }
            #upper
            {
                background-color: purple;
                height: 50px;
                left: 225px;
                position: absolute;
                top: 0px;
                width: 50px;
            }
            #lower
            {
                background-color: yellow;
                height: 50px;
                left: 225px;
                position: absolute;
                top: 400px;
                width: 50px;
            }
            #end
            {
                background-color: black;
                height: 50px;
                left: 500px;
                position: absolute;
                top: 200px;
                width: 50px;
            }
            #testDiv
            {
                animation-duration: 4s;
                animation-fill-mode: both;
                animation-delay: 1s;
                background-color: blue;
                border-width: 10px;
                height: 50px;
                position: absolute;
                width: 50px;
            }
        </style>
        <script type="text/javascript">
            function startTest()
            {
                document.body.offsetWidth;
                var element = document.getElementById("testDiv");
                element.style["animationName"] = "testAnimation";
            }
        </script>
    </head>
    <body onload="startTest()">
        <p>Test passes if the blue box slides directly from the orange box to the black box without first going to either the yellow or purple boxes.</p>
        <div id="parent">
            <div id="start"></div>
            <div id="upper"></div>
            <div id="lower"></div>
            <div id="end"></div>
            <div id="testDiv"></div>
        </div>
    </body>
</html>
